package com.dxy.yesas2020goals.study.partone.disignpattern.factorypattern.payment;

/**
 * @author victorydeng
 * @Classname PayTest
 * @Description TODO
 * @Date 2020/2/25 18:20
 * @Created by victorydeng
 */
public class PayTest {

  public static void main(String[] args) {
    PayFactory payFactory = new PayFactory();
    //使用支付宝付钱
    payFactory.pay(IAlipay.class).pay(System.currentTimeMillis());
    //使用微信付钱
    payFactory.pay(IWxpay.class).pay(System.currentTimeMillis());
    //使用银联付钱
    payFactory.pay(IUnionBankPay.class).pay(System.currentTimeMillis());
    //使用跨境支付付钱
    payFactory.pay(IKuaJingPay.class).pay(System.currentTimeMillis());
  }

}
